package com.corpgovernment.common.config;

import com.corpgovernment.common.aspect.CarryQueryParamAdapter;
import com.corpgovernment.common.aspect.SetQueryParamAdapter;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

/**
 * @author zl.cui
 * @date 2023/11/22
 */
@Configuration
public class TraceIdMvcConfig implements WebMvcConfigurer {
    @Override
    public void addInterceptors(InterceptorRegistry registry) {
        registry.addInterceptor(new SetQueryParamAdapter());
        registry.addInterceptor(new CarryQueryParamAdapter());
    }
}
